#include<stdio.h>
unsigned long factorial(int n)
{
 if(n<=1)
  return 1;
 else
  return (long)n*factorial(n-1);
}
int main()
{
 int i;
 //compute factorial from 1 to 10
 for(i=1;i<=10;i++)
  printf("\n Factorial of %d is: %ld",i,factorial(i));
 return 0;
}

